<template>
  <div style="width:500px;height: 300px;"><CXChart :options="option" :width="'500px'" :height="'300px'" /></div>
</template>
<script lang="ts" setup>
  import CXChart from "baseCom/CXChart/index.vue";
  const months = ["2023-01", "2023-02", "2023-03", "2023-04", "2023-05", "2023-06", "2023-07", "2023-08", "2023-09", "2023-10", "2023-11", "2023-12"];
  const scores = [78, 80, 79, 81, 82, 80, 83, 85, 84, 86, 85, 87];

  const option = {
    title: {
      text: '每月全体学生平均分变化趋势'
    },
    tooltip: {
      trigger: 'axis'
    },
    xAxis: {
      type: 'category',
      data: months,
      boundaryGap: false
    },
    yAxis: {
      type: 'value'
    },
    series: [{
      name: '平均分',
      type: 'line',
      data: scores,
      smooth: true,
      areaStyle: {}
    }]
  };
</script>
